package controller;

import org.apache.log4j.Logger;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

/**
 * Created by Dell on 2018/12/29.
 */
@Controller
public class IndexController {
    private Logger logger = Logger.getLogger(IndexController.class);

    //RequestMapping表示用哪个url来对应(此处："/index")
    @RequestMapping("/index")
    public String index(){
        //System.out.println("hello,SpringMVC!");
        logger.info("hello,SpringMVC!");
        return "index";
    }
}
